home *** CD-ROM | disk | FTP | other *** search
/ Mac Magazin/MacEasy 43 / Mac Magazin and MacEasy Magazine CD - Issue 43.iso / Software / Mobiles Büro / Newton / Newton Entwickler / DIL 2.0 Sample Code ƒ / SoupDrink-Mac-4 / README.SoupDrink < prev    next >
Text File  |  1997-04-17  |  3KB  |  62 lines

  1. /*    
  2. **      Newton Developer Technical Support Sample Code
  3. **
  4. **      SoupDrink, a sample of the Newton Desktop Integration Libraries (DILs)
  5. **
  6. **      by David Fedor, Rob Langhorne and J. Christopher Bell
  7. **
  8. **      Copyright © 1995-1997 by Apple Computer, Inc.  All rights reserved.
  9. **
  10. **      You may incorporate this sample code into your applications without
  11. **      restriction.  This sample code has been provided "AS IS" and the
  12. **      responsibility for its operation is 100% yours.  You are not
  13. **      permitted to modify and redistribute the source as "DTS Sample Code."
  14. **      If you are going to re-distribute the source, we require that you
  15. **      make it clear in the source that the code was descended from
  16. **      Apple-provided sample code, but that you've made changes.
  17. */
  18.  
  19.  
  20. This is a complete MacOS application which demonstrates use of the CDILs and the
  21. FDILs.  It is designed to communicate with the SoupDrink-Newton package, which
  22. is a separate sample code project.
  23.  
  24. You can obtain the DIL libraries, headers and documentation from 
  25. http://dev.info.apple.com/newton/tools/dils.html
  26.  
  27. Most of the interesting DIL code can be found in the file Engine.c, which holds
  28. the cross-platform code which makes most of the DIL API calls.
  29.  
  30. The routine SetupPortMenu() demonstrates how to dynamically find the names of
  31. the available ports - these can be different on different models of MacOS
  32. computers, and change in localized versions of the MacOS System.
  33.  
  34. The SoupDrink application has two test scripts.  The first, "Soup Drink", will
  35. read the entire contents of any soup on the Newton device.  It does this by
  36. sending a command to the Newton device indicating the name of the soup to read,
  37. and then repeatedly reading frames which are sent from the Newton application,
  38. converting them to text, and writing them to the file SoupData.out.
  39.  
  40. The second test script, "Add New Name Card", constructs a name card frame for
  41. the built-in Names application, and sends it to the Newton device.  The Newton
  42. SoupDrink application adds it to the Names soup.
  43.  
  44. Note that the CSTR resources found in the file SoupDrink.rsrc must be linked in
  45. to every DIL application.  They are used internally by the CDIL to find the
  46. appropriate Communications Toolbox files.  These CSTR resources can also be
  47. found in the file CSTR.rsrc, which does not contain the SoupDrink-specific
  48. resources.
  49.  
  50. NOTE: The "SPIT" command is supported for compatibility with older versions of
  51. this sample. If the SPIT command was sent instead of DRNK, a text version of
  52. the entry (NOT a frame) was sent. This was relevant only to a bug in some
  53. versions of Newton 1.x. See engine.c for more info.
  54.  
  55.  
  56. Modified April 1997 - cleaned up a few small bugs, and converted to CodeWarrior 11.
  57. Note that SoupDrink still uses the old ANSI libraries, not the MSL ones which
  58. are the default ones for CW11.  Why?  Because the MSL libraries don't by default
  59. include one for 2-byte integers and 8-byte longs, which is what the Mac DILs
  60. use right now.  If you build your own 2i8d MSL library, things should work fine
  61. too.
  62.